name: String::new(),
src_path: PathBuf::new(""),
metadata: None,
- doc: true,
+ doc: false,
doctest: false,
harness: true,
for_host: false,
src_path: src_path.to_path_buf(),
metadata: Some(metadata),
doctest: true,
+ doc: true,
..Target::blank()
}
}
name: name.to_string(),
src_path: src_path.to_path_buf(),
metadata: metadata,
+ doc: true,
..Target::blank()
}
}
fn main() {}
"#);
+ println!("build");
assert_that(p.cargo_process("build").arg("-v"),
execs().with_status(0));
p.root().move_into_the_past().unwrap();
File::create(&p.root().join("src/lib.rs")).unwrap();
p.root().move_into_the_past().unwrap();
+ println!("test");
assert_that(p.cargo("test").arg("-vj1"),
execs().with_status(0)
.with_stdout(format!("\
", compiling = COMPILING, running = RUNNING, doctest = DOCTEST).as_slice()));
+ println!("doc");
assert_that(p.cargo("doc").arg("-v"),
execs().with_status(0)
.with_stdout(format!("\
{compiling} foo v0.5.0 (file://[..])
{running} `rustdoc [..]`
-{running} `rustc [..]`
", compiling = COMPILING, running = RUNNING).as_slice()));
File::create(&p.root().join("src/main.rs")).unwrap()
.write_all(b"fn main() {}").unwrap();
+ println!("run");
assert_that(p.cargo("run"),
execs().with_status(0)
.with_stdout(format!("\